home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
System Booster
/
System Booster.iso
/
Archives
/
GNU
/
emacs_src.lha
/
src
/
amiga
/
emacs-18.59
/
unix.lha
/
unix
/
src
/
utime.c
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
C/C++ Source or Header
|
1992-08-25
|
379 b
|
23 lines
#include "amiga.h"
#include "timeconvert.h"
#include <stdlib.h>
#include <time.h>
#include <utime.h>
int utime(char *file, struct utimbuf *times)
{
struct DateStamp date;
time_t mtime;
chkabort();
if (times) mtime = times->modtime;
else mtime = time(0);
if (mtime == -1) return 0;
_gmt2amiga(mtime, &date);
if (SetFileDate(file, &date)) return 0;
ERROR;
}